using VSTalk.Engine.Settings;

namespace VSTalk.Engine.Core.Context
{
    public class ModelInitializer : IModelInitializer
    {
        public IAccountDeserializer Deserializer { get; set; }

        public ModelInitializer()
        {
            Deserializer = new FileAccountSerializer();
        }

        public IModelContext InitializeContext()
        {
            var modelContext = new ModelContext();
            modelContext.Account = Deserializer.Deserialize();
            return modelContext;
        }
    }
}